<%= meta %>

<title>图片列表</title>
</head>
<body>
  <%= header %>
  <%= menu %>
  <section class="Hui-article-box">
  	<nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 众筹项目 <span class="c-gray en">&gt;</span> 新建项目列表  <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px" href="javascript:location.replace(location.href);" title="刷新" ><i class="Hui-iconfont">&#xe68f;</i></a></nav>
  	<div class="Hui-article">
  		<article class="cl pd-20">
  			<div class="text-c">
  				项目编号：<input type="text" class="input-text" style="width:120px;">　
  				项目名称：<input type="text" class="input-text" style="width:120px;">　
  				<button name="" id="" class="btn btn-success radius" type="submit"><i class="Hui-iconfont">&#xe665;</i> 查 询</button>
  			</div>
  			<div class="cl pd-5 bg-1 bk-gray mt-20">
  				<span class="l"></span>
  				<span class="r" style="line-height:30px;">共有数据：<strong>1</strong> 条</span> </div>
          <div class="mt-20">
    				<table class="table table-border table-bordered table-bg table-hover table-sort">
    					<thead>
    						<tr class="text-c">
    							<th width="40">编号</th><th width="100">项目名称</th>
    							<th width="100">众筹类型</th><th>项目分类</th><th width="80">众筹金额</th><th width="70">预热天数</th>
                  <th width="60">众筹天数</th><th>提交时间</th><th width="100">操作</th>
    						</tr>
    					</thead>
    					<tbody>
    						<tr class="text-c">
    							<td>1</td><td>北京玉之光众筹</td><td>收益权众筹</td><td>医美</td>
    							<td>100万</td><td>3</td><td>30</td><td>2017/02/11 14:33:33</td>
                  <td class="f-14 td-manage">
                    <a style="text-decoration:none" class="ml-5" onClick="project_edit('众筹-已发布项目列表-详情','众筹-已发布项目列表-详情.html','10001')" href="javascript:;" title="查看"><i class="Hui-iconfont">&#xe725;</i></a>
    								<a style="text-decoration:none" onClick="project_stop(this,'10001')" href="javascript:;" title="下架"><i class="Hui-iconfont">&#xe6de;</i></a>
    							</td>
    						</tr>
    					</tbody>
    				</table>
    			</div>
    	</article>
  	</div>
  </section>

  <%= footer %>

<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript" src="lib/My97DatePicker/4.8/WdatePicker.js"></script>
<script type="text/javascript" src="lib/datatables/1.10.0/jquery.dataTables.min.js"></script>
<script type="text/javascript" src="lib/laypage/1.2/laypage.js"></script>
<script type="text/javascript">
//*项目-编辑*/
function project_edit(title,url,id,w,h){
	var index = layer.open({
		type: 2,
		title: title,
		content: url
	});
	layer.full(index);
}
/*项目-删除*/
function project_del(obj,id){
	layer.confirm('确认要删除吗？',function(index){
		$.ajax({
			type: 'POST',
			url: '',
			dataType: 'json',
			success: function(data){
				$(obj).parents("tr").remove();
				layer.msg('已删除!',{icon:1,time:1000});
			},
			error:function(data) {
				console.log(data.msg);
			},
		});
	});
}
/*项目-下架*/
function project_stop(obj,id){
	layer.confirm('确认要下架吗？',function(index){
		$(obj).parents("tr").find(".td-manage").prepend('<a style="text-decoration:none" onClick="project_start(this,id)" href="javascript:;" title="发布"><i class="Hui-iconfont">&#xe603;</i></a>');
		$(obj).parents("tr").find(".td-status").html('<span class="label label-defaunt radius">已下架</span>');
		$(obj).remove();
		layer.msg('已下架!',{icon: 5,time:1000});
	});
}

/*项目-发布*/
function project_start(obj,id){
	layer.confirm('确认要发布吗？',function(index){
		$(obj).parents("tr").find(".td-manage").prepend('<a style="text-decoration:none" onClick="picture_stop(this,id)" href="javascript:;" title="下架"><i class="Hui-iconfont">&#xe6de;</i></a>');
		$(obj).parents("tr").find(".td-status").html('<span class="label label-success radius">已发布</span>');
		$(obj).remove();
		layer.msg('已发布!',{icon: 6,time:1000});
	});
}
/*项目-申请上线*/
function project_shenqing(obj,id){
	$(obj).parents("tr").find(".td-status").html('<span class="label label-default radius">待审核</span>');
	$(obj).parents("tr").find(".td-manage").html("");
	layer.msg('已提交申请，耐心等待审核!', {icon: 1,time:2000});
}

/*项目-删除*/
function project_del(obj,id){
	layer.confirm('确认要删除吗？',function(index){
		$(obj).parents("tr").remove();
		layer.msg('已删除!',{icon:1,time:1000});
	});
}
</script>
<!--/请在上方写此页面业务相关的脚本-->
</body>
</html>
